<?php
class AboutController extends AppController
{	
    public $name = 'About';

    public $uses = array('About', 'Link', 'Customer');

    public function Index()
    {
	$data = $this->About->findById(1);	
        $this->request->data = $data;

        $links = $this->Link->find('all', array(
            'conditions' => array('Link.link_visible' => 1),
            'order' => array(
                'Link.link_rating' => 'desc',
            ),
        ));
        $this->set(compact('links'));

        $customers = $this->Customer->find('all', array(
            'conditions' => array('Customer.customer_visible' => 1),
            'order' => array(
                'Customer.customer_priority' => 'desc',
            ),
        ));
        $this->set(compact('links', 'customers'));
    }
}
